package com.ssy.lingxi.system.service;

import com.ssy.lingxi.common.response.Wrapper;
import com.ssy.lingxi.system.dto.request.*;
import com.ssy.lingxi.system.dto.response.MiddlegroundMenuResponse;
import org.springframework.web.bind.annotation.RequestBody;

import javax.servlet.http.HttpServletRequest;
import java.util.List;

/**
 * 权限菜单管理业务层
 *
 * @author wrc
 * @date 2020/5/11
 */
public interface MiddlegroundMenuService {
    /**
     * 查询所有权限菜单列表
     *
     * @author wrc
     * @date 2020/5/11
     */
    Wrapper<List<MiddlegroundMenuResponse>> menuList();

    /**
     * 添加权限菜单实体类
     *
     * @author wrc
     * @date 2020/5/11
     */
    Wrapper menuAdd(MiddlegroundMenuAddRequest request,HttpServletRequest httpServletRequest);

    /**
     * 删除权限菜单
     *
     * @author wrc
     * @date 2020/5/12
     */
    Wrapper menuDelete(MiddlegroundMenuDeleteRequest request);
    /**
    * 根据角色ID查询权限菜单列表
    * @author wrc
    * @date 2020/5/12
     * @return
    */
    Wrapper<List<MiddlegroundMenuResponse>> menuListByRoleId(HttpServletRequest request);

    /**
    * 配置角色权限
    * @author wrc
    * @date 2020/5/13
    */
    Wrapper menuRoleBinding(MenuBindingRoleRequest request);

    /**
    * 获取菜单详情
    * @author wrc
    * @date 2020/7/24
     * @return
    */
    Wrapper<MiddlegroundMenuUpdateRequest> menuDetails(MenuDetailsRequest request);


    /**
    * 修改菜单
    * @author wrc
    * @date 2020/7/27
    */
    Wrapper menuUpdate(@RequestBody MiddlegroundMenuUpdateRequest request);
}
